public class Course {
    private String courseName;
    private int courseId;
    private double credit;

    public void displayCourseInfo (){
        System.out.println("课程名："+courseName+"课程号："+courseId+"学分："+credit);
    }
    public Course(String courseName, int courseId, double credit) {
        this.courseName = courseName;
        this.courseId = courseId;
        this.credit = credit;
    }
}
